package com.itheima.reggie.entity.dto;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;

/**
 * 分页查询Dto
 *
 * @Author Vsunks.v
 * @Date 2023/2/5 9:25
 * @Blog blog.sunxiaowei.net/996.mba
 * @Description: 分页查询Dto
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class PageDto {

    @NotNull(message = "页数不能为空")
    @Min(value = 1,message = "页码不能小于1")
    private Integer page;

    @NotNull(message = "页面大小不能为空")
    @Min(value = 1,message = "页面大小不能小于1")
    // @NotNull()
    // @Min(value = 1)
    private Integer pageSize;


    private String name;
}
